import biosbob.targets.xilinx.GCMicroBlaze;

metaonly module BuildC inherits amaret.freestyle.core.distro.IBaseC {

    readonly config gnu.targets.ITarget.Module GNU_Target;
}

implementation {

    TOOLSDIR := "c:/Xilinx/11.1/SDK/gnu/microblaze/nt";
    
    final Target := GCMicroBlaze;
    
    Target.platform := 'biosbob.platforms.cs153';
    Target.rootDir := TOOLSDIR;
    
    Target.profiles['whole_program'] := {};
    Target.profiles['whole_program_debug'] := {};
    
//    Target.profiles['whole_program'].filters := [{moduleName: 'biosbob.filters.blas.FilterGCC'}];
//    Target.profiles['whole_program_debug'].filters := [{moduleName: 'biosbob.filters.blas.FilterGCC'}];
    
    final GNU_Target := GCMicroBlaze;
    
    GNU_Target.LONGNAME := "bin/mb-gcc";

    GNU_Target.ccOpts.prefix += " -ffunction-sections -fdata-sections";
}
